package com.hk.result;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.List;

/**
 * 封装分页查询结果
 */
@Data
public class PageResult implements Serializable {


    public PageResult() {
    }

    public PageResult(long total, List rows) {
        this.total = total;
        this.rows = rows;
        this.code = 200;
        this.msg = "success";
    }

    private Integer code;

    private String msg;

    private long total; //总记录数

    private List  rows; //当前页数据集合

}
